home *** CD-ROM | disk | FTP | other *** search
/ Enigma Amiga Life 112 / EnigmaAmiga112CD.iso / dalla rivista / workbench / freedom / docs / freetype / readme < prev    next >
Text File  |  1998-07-03  |  16KB  |  486 lines

  1.  
  2.  
  3.                Welcome to the
  4.  
  5.           F R E E T Y P E    P R O J E C T
  6.  
  7.               www.freetype.org
  8.  
  9.             Public  Release 1.1
  10.  
  11.            The FREE TrueType Font Engine
  12.  
  13.     Copyright 1996 David Turner    <turner@enst.fr>
  14.             - 1998 Robert Wilhelm  <robert@physiol.med.tu-muenchen.de>
  15.                    Werner Lemberg  <wl@gnu.org>
  16.  
  17.  
  18. Table Of Contents:
  19.  
  20.     A. Introduction
  21.  
  22.     B. The FreeType mini-FAQ
  23.  
  24.     C. How to use the test programs
  25.  
  26.     D. How to use the programs in the 'contrib' directory
  27.  
  28.  
  29.  
  30. A. Introduction:
  31.  
  32.   The FreeType engine is a free and portable TrueType font rendering
  33.   engine.  It  has been developed to  provide TT support  to a great
  34.   variety of platforms and environments.
  35.   
  36.   Notice that  FreeType is a *library*.   It is *not*  a font server
  37.   for your preferred environment, even though it has been written to
  38.   allow the design of many font servers.
  39.  
  40.   To our knowledge, this  is the only royalty-free complete TrueType
  41.   engine available.   Moreover, its  quality fully matches  these of
  42.   Windows or  the Macintosh,  a thing that  cannot be said  for most
  43.   other commercial engines available.
  44.  
  45.   FreeType is  a clean-room implementation that is  not derived from
  46.   the original TrueType engine developed by Apple and Microsoft.  It
  47.   has  been created  with the  sole help  of the  published TrueType
  48.   specifications, which, to our  great surprise and pain, turned out
  49.   to be extremely  poor or misleading in critical  areas.  Much hard
  50.   work   has  been   undertaken  to   solve   numerous  ambiguities;
  51.   nevertheless, its end result is a portable, fast quality renderer!
  52.  
  53.   The  library itself takes  about 55kByte  of Intel  code, complete
  54.   with  a  TrueType  byte-code  interpreter and  a  high-performance
  55.   scan-line converter.
  56.   
  57.   You will find in this release:
  58.  
  59.      - a TrueType engine, with source code in ANSI C and Pascal.
  60.  
  61.        The C source  code has been successfully compiled  and run on
  62.        various platforms,  including MS-DOS, OS/2,  Amiga, Linux and
  63.        several  other variants of  Unix.  It  should be  portable to
  64.        many other platforms too.
  65.  
  66.        The Pascal code has been successfully compiled and run on DOS
  67.        (Borland's BP7) and OS/2 (fPrint's Virtual Pascal).  A Delphi
  68.        port is in beta (the code in freetype/pascal compiles).
  69.  
  70.      - An API  to be used  by client applications and  font servers,
  71.        providing several low level  abstractions that can be used to
  72.        open font files and collections, create point sizes and load,
  73.        process and render glyph outlines and bitmaps.
  74.  
  75.      - Support for the following features:
  76.  
  77.          o Font smoothing, a.k.a. gray-level rendering.
  78.  
  79.              Just like  Win95, the renderer uses  a 'fine' algorithm
  80.              that only smoothes  diagonals and curves, while keeping
  81.              the horizontal and vertical stems intact.
  82.              
  83.              This results in glyphs that are much more legible than
  84.              the "fuzzy" ones generated by programs like Acrobat.
  85.  
  86.          o Support for all character mapping formats.
  87.  
  88.          o A full-featured TrueType byte-code interpreter.
  89.  
  90.              The  engine  is able  to  hint  the  glyphs to  produce
  91.              excellent  output  at small  sizes.   It was  extremely
  92.              difficult  to  get this  component  right,  due to  the
  93.              ambiguous   and  misleading   TrueType  specifications.
  94.              However,   we  now   *match*   Windows  and   Macintosh
  95.              qualities.
  96.  
  97.          o TrueType  collection  support,  when  several  fonts  are
  98.            embedded in the same file.
  99.  
  100.          o Support for extensions.
  101.  
  102.              It is  now possible to  extend the library in  parts to
  103.              support additional features,  like optional tables that
  104.              are not considered by the current core engine.
  105.  
  106.          o Kerning support.
  107.  
  108.              Provided  as  a  sample  extension with  this  release,
  109.              kerning tables can be accessed from a TrueType font for
  110.              applications that need it.
  111.  
  112.          o New in 1.1: Support for vertical metrics.
  113.  
  114.              It  is  now  possible  to load  vertical  metrics  when
  115.              they're  present  in  a  font  file.   Metrics  can  be
  116.              retrieved  glyph  by glyph,  using  the  loader, or  in
  117.              arrays with a new API.
  118.  
  119.          o New in 1.1: Support for thread-safety and re-entrancy.
  120.  
  121.              This support is now in beta.  You'll need to specialize
  122.              the  file  "ttmutex.c"  for  your platform  to  include
  123.              system-specific synchronization calls.
  124.  
  125.   Note also that:
  126.  
  127.    - Though development  of the library is mainly  performed on OS/2
  128.      and Linux, the library does not contain system-specific code.
  129.    
  130.    - The  package contains some  graphics drivers  used by  the test
  131.      programs for display purposes  on MS-DOS, OS/2, Amiga, and X11.
  132.      These  drivers are  absolutely  not mandatory  for running  the
  133.      FreeType engine.  Some console-mode test programs like 'ftlint'
  134.      or 'ftdump' don't use graphics at all.
  135.    
  136.    - FreeType 1.1  is _not_ binary compatible with  1.0, which means
  137.      that you will need to  recompile your programs if they used the
  138.      engine as a shared library (libttf.so on Linux, or FreeType.dll
  139.      on Windows).  See the file 'freetype/docs/changes.txt' for more
  140.      information.
  141.  
  142.  
  143. B. The FreeType mini-FAQ:
  144.  
  145.   Summary:
  146.  
  147.   0. Where to find the latest FreeType release?
  148.  
  149.   1. What do you mean by 'Public Release'?
  150.  
  151.   2. Did the API changed since the beta ?
  152.  
  153.   3. What does the 'Free' in FreeType means?
  154.      Can you use it in a commercial product? (YES!)
  155.  
  156.   4. I have  made a small program  based on the test  programs but I
  157.      would like to know how to do xxx?
  158.  
  159.   5. When will I  be able to use FreeType  to display TrueType fonts
  160.      under X11, OS/2 or Wine? (NOW!)
  161.  
  162.   6. Trying  to  compile  the  FreeType  sources gives  me  lots  of
  163.      warnings with my ANSI C compliant compiler!
  164.  
  165.   ------------------------------------------------------------------
  166.  
  167.   0. Where to find the latest FreeType release?
  168.  
  169.        The  latest package  is  usually uploaded  to various  source
  170.        repositories, like SunSite, SimTel, or Hobbes.  There are two
  171.        archive formats (zip and  tar.gz), which also differ by their
  172.        CR/LF conventions.
  173.  
  174.        * for DOS and OS/2: 'ft-10.zip'
  175.  
  176.          which should be available at:
  177.  
  178.          Hobbes: ftp://ftp.cdrom.com/pub/os2/fonts
  179.          SimTel: ftp://oak.oakland.edu/pub/simtel.net/msdos/graphics
  180.  
  181.        * for UNIX and Amiga: 'freetype-1.1.tar.gz'
  182.  
  183.          look at:
  184.  
  185.          SunSite: ftp://sunsite.unc.edu/pub/Linux/X11/fonts
  186.  
  187.        * As  uploading  can take  several  days  before the  package
  188.          becomes available to the  public, we advise you to download
  189.          it from our own ftp site  if you read this message few days
  190.          after the announcement at:
  191.        
  192.          ftp://ftp.freetype.org/pub/freetype
  193.  
  194.  
  195.        We have registered the  "freetype.org" domain.  Our main page
  196.        is now at:
  197.  
  198.                         http://www.freetype.org
  199.  
  200.                        (Screen shots available)
  201.  
  202.        There are also three mailing lists:
  203.        
  204.          o freetype@lists.lrz-muenchen.de 
  205.  
  206.              Discusses  general use of  FreeType, future  and needed
  207.              additions,   as  well   as   many  other   font-related
  208.              discussions which do not  always relate directly to the
  209.              FreeType code itself...
  210.  
  211.  
  212.          o freetype-devel@lists.lrz-muenchen.de
  213.  
  214.              Discusses  development,   design  choices,  portability
  215.              issues, internals, specific licenses, etc.
  216.        
  217.  
  218.          o freetype-bugs@freetype.org
  219.  
  220.              To  report bugs you  believe come  from the  engine :-)
  221.              Notice the different address! (You can't subscribe this
  222.              list yet, sorry.)
  223.  
  224.  
  225.        To subscribe, send the usual subscription commands to:
  226.        
  227.            majordomo@lists.lrz-muenchen.de
  228.        
  229.        
  230.        Any suggestions/bug reports are welcome.
  231.        
  232.   ------------------------------------------------------------------
  233.  
  234.   1. What do you mean by 'Public Release'?
  235.  
  236.        This release fixes  some bugs found in FreeType  1.0, as well
  237.        as  provide  additional  capabilities  to  the  engine,  like
  238.        support for vertical metrics.
  239.  
  240.        The code has also  been cleaned for 16-bit compilers support,
  241.        better ANSI conformance (in order to get rid of warnings with
  242.        compilers other than gcc), beta multi-threaded support, etc.
  243.  
  244.        Note that FreeType will soon go under a major re-design.  The
  245.        library will evolve from a TrueType-specific driver to a more
  246.        general  and  high-level  text  rendering library,  with  the
  247.        ability  to  support  several  font  file  formats  (bitmaps,
  248.        TrueType, hopefully Type1  PostScript).  The first "try" will
  249.        be  released as FreeType  2.0, but  the font  driver(s) alone
  250.        will still be available for separate compilation.
  251.  
  252.        Of course, we keep the same license :-)
  253.  
  254.  
  255.   ------------------------------------------------------------------
  256.  
  257.   2. Did the API change since the beta ?
  258.  
  259.        Yes, there were a few changes  that are summed up in the file
  260.        'docs/changes.txt'.    Please   read   it  thorougly   before
  261.        modifying your code to adapt to this release.
  262.  
  263.        Normally, if your source only  used the FreeType 1.0 API, and
  264.        _didn't_  access  directly   the  outline  structures  (these
  265.        changed in  the way), it  should recompile flawlessly  on the
  266.        first try (with very small exceptions).
  267.  
  268.  
  269.   ------------------------------------------------------------------
  270.  
  271.   3. What does the 'Free' in FreeType means?
  272.      Can you use it in a commercial product? (YES!)
  273.  
  274.        We  have placed  this  release under  the  same old  FreeType
  275.        license.
  276.        
  277.        It  was inspired by  the BSD,  Artistic and  IJG (Independent
  278.        JPEG group)  ones, which  specifically encourage use  of this
  279.        software in commercial products!
  280.  
  281.        The reason we did this is  that we believe that TrueType is a
  282.        very useful technology, and want  to make it available on all
  283.        machines and platforms.  The  license is there to ensure that
  284.        the engine can be spread as widely as possible.
  285.  
  286.        However, free  does not mean  public domain.  This  engine is
  287.        copyrighted  by its  authors, and  they will  fiercely defend
  288.        their rights.
  289.        
  290.  
  291.   ------------------------------------------------------------------
  292.  
  293.   4. I have  made a small program  based on the test  programs but I
  294.      would like to know how to do xxx?
  295.  
  296.        (Where   xxx  is   a   feature  lacking   from  the   current
  297.        implementation).
  298.  
  299.        First of  all, read the documentation.  The  user guide gives
  300.        some basic hints and concepts.   You can also read the source
  301.        code of the  test programs that you didn't  consider yet.  If
  302.        you're really stuck, mail your question to:
  303.  
  304.                        freetype@lists.lrz-muenchen.de
  305.  
  306.        We'll try to help you.
  307.  
  308.  
  309.   ------------------------------------------------------------------
  310.  
  311.   5. When will I  be able to use FreeType  to display TrueType fonts
  312.      under X11, OS/2, or Wine?
  313.  
  314.        You can  already do  that under  X11 and OS/2  :-)  Go to the
  315.        FreeType   web   page   (www.freetype.org)   for   up-to-date
  316.        information.
  317.  
  318.        And yes, it looks terrific!
  319.  
  320.        For  X11,  you  could  also   take  a  look  at  "xfstt",  an
  321.        independent TrueType font server  for Unix which doesn't rely
  322.        on the FreeType code.
  323.  
  324.        You're welcome to volunteer for other platforms, like:
  325.  
  326.             Amiga, RISC OS, BeOS, and others
  327.  
  328.        Please contact  freetype-devel@lists.lrz-muenchen.de for more
  329.        information.
  330.  
  331.  
  332.   ------------------------------------------------------------------
  333.  
  334.   6. Trying  to  compile  the  FreeType  sources gives  me  lots  of
  335.      warnings with my ANSI C compliant compiler!
  336.  
  337.        We use gcc as our reference compiler for warnings. This means
  338.        that we use the "-ansi  -pedantic -Wall" flags and try to get
  339.        rid of warnings in this situation.
  340.  
  341.        If you're compiling with  another compiler, you may encounter
  342.        warnings, not errors.
  343.  
  344.        We have spent much efforts  to reduce seriously the number of
  345.        warnings produced  by major compilers,  including Visual Age,
  346.        Visual C++ and Borland C++.
  347.  
  348.        Note  that the  Borland  compilers seem  to  produce lots  of
  349.        irrelevant warnings (like 'potential loss of precision').
  350.  
  351.  
  352.  
  353. C. How to use the test programs:
  354.  
  355.   This package includes several test programs in the "freetype/test"
  356.   directory.  Read the "HOWTO" files to learn how to compile them.
  357.  
  358.   Note  that  all  test  programs   share  the  same  key  map  when
  359.   displaying.  Using the arrow or function keys would have been good
  360.   to but  we preferred  a common map  rather than specifying  it for
  361.   each platform:
  362.  
  363.     x :   fine counter-clockwise rotation  (ftzoom only)
  364.     c :   fine clockwise rotation          (ftzoom only)
  365.  
  366.     v :   fast counter-clockwise rotation  (ftzoom only)
  367.     b :   fast clockwise rotation          (ftzoom only)
  368.  
  369.     h :   toggle hinting on/off
  370.  
  371.     + :   fast scale up
  372.     - :   fast scale down
  373.     u :   fine scale up
  374.     j :   fine scale down
  375.  
  376.     l :   go to next glyph
  377.     k :   go to previous glyph
  378.  
  379.     o :   go to tenth next glyph
  380.     i :   go to tenth previous glyph
  381.  
  382.     9 :   go to hundredth next glyph (useful for CJK fonts)
  383.     0 :   go to hundredth previous glyph
  384.  
  385.     ( :   go to 1000th next glyph
  386.     ) :   go to 1000th previous glyph
  387.  
  388.     { :   go to 10000th next glyph
  389.     } :   go to 10000th previous glyph
  390.  
  391.   ESC :
  392.     q :   exit
  393.  
  394.  
  395.   These keys were chosen because they're available on all platforms.
  396.  
  397.  
  398. - FTTIMER:
  399.  
  400.   This is a simple performance timer for the engine.  It will load a
  401.   TrueType font given as an argument and try to render each glyph as
  402.   fast as possible, giving the total time elapsed.
  403.  
  404.   This program only times the scan-line converter's job by rendering
  405.   all glyphs at a size of 400pt.
  406.  
  407.   (supports font-smoothing and display)
  408.  
  409.  
  410. - FTZOOM:
  411.  
  412.   This program  is a very  simple glyph viewer.  Specify  a TrueType
  413.   font as an argument, and it will  try to load it and allows you to
  414.   view/scale/rotate  any  glyph  of  it.  Supports  font  smoothing.
  415.   Doesn't hint glyphs.  Use the -p and -e flags to select a CMAP.
  416.   
  417.  
  418. - FTLINT:
  419.  
  420.   This program will hint each glyph of a font file, at a given point
  421.   size.  This is useful to detect bugs in the interpreter (or in the
  422.   font file).
  423.  
  424.  
  425. - FTVIEW:
  426.  
  427.   This program  will display  all glyphs in  a given  font, applying
  428.   hinting to  each one.   Try it, the  results are  really pleasant.
  429.   Supports font-smoothing.
  430.  
  431.   You can change the point  size whenever you want.  The OS/2 viewer
  432.   comes  with a magnifying  sub-window that  lets you  inspect pixel
  433.   details (like font-smoothing).
  434.  
  435.  
  436. - FTDUMP:
  437.  
  438.   A simple TrueType font or collection dumper.
  439.  
  440.  
  441. - FTSTRING:
  442.  
  443.   A  simple program  to show  off string  text generation.   Used to
  444.   display  a given  message on  the screen  with a  given  font, and
  445.   eventually resize it as you want.
  446.  
  447.  
  448. - FTSTRPNM:
  449.  
  450.   Use this program to convert a rendered text string into the PGM or
  451.   PBM format which can be  further converted to popular formats like
  452.   GIF or PNG with the netpbm tool suite.
  453.  
  454.  
  455. - FTERROR:
  456.  
  457.   This small test program  is UNIX-specific.  It tests the gettext()
  458.   functionality for internationalized messages.
  459.  
  460.  
  461.  
  462. D. HOW TO USE THE PROGRAMS IN THE 'CONTRIB' DIRECTORY:
  463.  
  464.   These  programs   (currently  ftos2,  ttf2bmf,   and  ttf2pk)  are
  465.   contributions to FreeType and not  really part of it.  Please read
  466.   the documentation  files in  the respective subdirectories  how to
  467.   compile and install them.
  468.  
  469.  
  470. Of course,  all source  code is provided  'as is'.  Please  read the
  471. file 'license.txt' for more information.
  472.  
  473. We hope  you'll find this engine  useful, and look  forward to file.
  474. your feed-back.  We're of course  very interested in bug reports, as
  475. well as FreeType success stories :-)
  476.  
  477.  
  478. Thanks for your time and consideration,
  479.  
  480.  
  481.     David Turner, Robert Wilhelm, Werner Lemberg,
  482.     and all the FreeType enthusiasts...
  483.  
  484.  
  485. --- end of readme.1st --
  486.